package com.rest.converter;

/**
 * Created by HP on 2018/12/13.
 */

public class ApiException extends RuntimeException {
    public int mErrorCode;
    public String errorMessage;

    public ApiException(int errorCode, String errorMessage) {
        super(errorMessage);
        mErrorCode = errorCode;
        this.errorMessage = errorMessage;
    }

    /**
     * 判断是否是token失效
     *
     * @return 失效返回true, 否则返回false;
     */
//    public boolean isTokenExpried() {
//        return mErrorCode == Constants.TOKEN_EXPRIED;
//    }
}
